;; EX-38.scm - Using Klank to audition 1RES SDIF files.

(require (lib "rss.ss" "rss"))

(define 1RES-data
  (cycles
   (vector->list
    (sdif-read-matrix-data (resolve "sdif/crotale.sdif") "1RES")) 4))

(Klank.ar (Decay.ar (Dust.ar (MouseX.kr 1 69)) 
		    (MouseY.kr 0.01 0.4) 
		    (PinkNoise.ar))
	  1 0 (Rand.ir 1 15)
	  (Klank.spec (first 1RES-data)
		      (second 1RES-data)
		      (map reciprocal (third 1RES-data))))

(Klang.ar 1 0 (Klang.spec (first 1RES-data)
			  (second 1RES-data)))

